package com.ph.shopping.facade.order.service.check;

import cm.ph.shopping.facade.order.request.OrderRequest;
import com.alibaba.dubbo.common.utils.CollectionUtils;

/**
 * @项目：phshopping-facade-order
 * @描述：商户下单参数必填校验
 * @作者： Mr.zheng
 * @创建时间：2017-03-23
 * @Copyright @2017 by Mr.zheng
 */
public class ParamsCheck {

    /**
     * 商户下单参数校验
     * @param merchantOrderRequest
     * @return boolean
     */
    public static boolean checkAddOrders(OrderRequest merchantOrderRequest) {
        if (null == merchantOrderRequest) return false;
        if (CollectionUtils.isEmpty(merchantOrderRequest.getProductOrderDTOList())) return false;
        return true;
    }
}
